﻿using BPMN.Domain.Entity.SysDictonary;
using BPMN.Domain.Entity.Custom;
using BPMN.Domain.Entity.User;
using Microsoft.EntityFrameworkCore;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using BPMN.Domain;

namespace BPMN.Infrastructure
{
    public class MyDbContext : DbContext
    {
        /// <summary>
        /// 构造函数.
        /// </summary>
        /// <param name="options"></param>
        public MyDbContext(DbContextOptions<MyDbContext> options) : base(options)
        {
        }

        public virtual DbSet<UserInfo> UserInfos { get; set; }
        public virtual DbSet<Role> Roles { get; set; }
        public virtual DbSet<Permission> Permissions { get; set; }
        public virtual DbSet<UserRole> UserRoles { get; set; }
        public virtual DbSet<RolePermission> RolePermissions { get; set; }

        /// <summary>
        /// 映射自定义扩展字段表
        /// </summary>
        public virtual DbSet<Extend> Extend { get; set; }
        public virtual DbSet<Attributes> Attributes { get; set; }

        public virtual DbSet<RoleAuth> RoleAuth { get; set; }
        public virtual DbSet<Menu> Menu { get; set; }


        public virtual DbSet<Dictionary> Dictionarys { get; set; }
        public virtual DbSet<DictionaryList> DictionaryLists { get; set; }
        public virtual DbSet<Custom> Customs { get; set; }
        /// <summary>
        /// 测试
        /// </summary>
        public virtual DbSet<Test> Tests { get; set; }
        public virtual DbSet<Test1> Test1 { get; set; }
    }
}
